package com.jyw.system.domain.vo;

import com.jyw.common.core.domain.entity.SysDept;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * @author 沈峻
 * @ClassName DeptCacheVo
 * @Description TODO
 * @Date 2023/8/25 17:48
 **/
@ApiModel("部门缓存对象")
@Data
@NoArgsConstructor
public class DeptCacheVo {

    @ApiModelProperty("id")
    private Long deptId;

    @ApiModelProperty("名称")
    private String deptName;

    @ApiModelProperty("上级部门id")
    private Long parentId;

    @ApiModelProperty("部门分类 0科室 1第三方")
    private Integer deptType;

    public DeptCacheVo(SysDept dept) {
        setDeptId(dept.getDeptId());
        setDeptName(dept.getDeptName());
        setParentId(dept.getParentId());
        setDeptType(dept.getDeptType());
    }
}
